package com.zxjbyte.yiyi.extension.job.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zxjbyte.yiyi.framework.tenant.db.TenantBasePO;
import lombok.Data;
import lombok.experimental.Accessors;

/**
 * @Author zhangxingjia
 * @Date 2024/1/2 17:24
 * @Version: 1.0
 */
@Data
@Accessors(chain = false)
@TableName("ext_quartz_job")
public class QuartzJobPO extends TenantBasePO {

    private static final long serialVersionUID = -163792759092766718L;

    // 自增主键
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    // 任务名称
    @TableField("job_name")
    private String jobName;

    // 任务组名
    @TableField("job_group")
    private String jobGroup;

    // cron表达式
    @TableField("cron_expression")
    private String cronExpression;

    // 处理器类名
    @TableField("handler_class_name")
    private String handlerClassName;

    // 处理器方法名
    @TableField("handler_method_name")
    private String handlerMethodName;

    // 方法参数
    @TableField("method_param")
    private String methodParam;

    // 任务配置
    @TableField("job_config")
    private String jobConfig;

    // 状态：0-正常，1-暂停
    @TableField("status")
    private Integer status;
}
